from django.urls import path, include
from django.urls import re_path as url
from . import views
from . import view2
app_name='login'#需要添加app名称，不然include无法找到该model,在html文件里需要加上app名

urlpatterns = [
    # 主页，用来显示类别等其他数据
    path('', views.login_view,name='login'),  # 用于打开登录页面
    path('index1/', views.index_1, name='index1'),
    path('register/', views.register, name='register'),
    path('create/', views.create, name='create'),
    path('index1/Proc_index/', include("proc.urls"), name='proc_index'),
    path('index1/Proc_index/', views.proc_index, name='proc_index'),
    path('index1/Warehouse_index/', include('warehouse.urls')),
    path('index1/live_info', views.Stream_info, name='stream_info'),
    url(r'^line/$', views.ChartView4.as_view(), name='demo4'),
    url(r'^lineUpdate/$', views.ChartUpdateView4.as_view(), name='demo4'),
    url(r'^line_test/$', views.home_page4, name='demo4'),
    url(r'^line5/$', views.ChartView5.as_view(), name='demo5'),
    url(r'^lineUpdate5/$', views.ChartUpdateView5.as_view(), name='demo5'),
    url(r'^line_test5/$', views.home_page5, name='demo5'),
    url(r'^line6/$', views.ChartView6.as_view(), name='demo6'),
    url(r'^lineUpdate6/$', views.ChartUpdateView6.as_view(), name='demo6'),
    url(r'^line_test6/$', views.home_page6, name='demo6'),
    url(r'^line7/$', views.ChartView7.as_view(), name='demo7'),
    url(r'^lineUpdate7/$', views.ChartUpdateView7.as_view(), name='demo7'),
    url(r'^line_test7/$', views.home_page7, name='demo7'),
    url(r'^line8/$', views.ChartView8.as_view(), name='demo8'),
    url(r'^lineUpdate8/$', views.ChartUpdateView8.as_view(), name='demo8'),
    url(r'^line_test8/$', views.home_page8, name='demo8'),
    path('index1/tim/', views.tim, name='tim'),
    url(r'^rank/$',view2.table_sales_rank,name='sa_rank'),
    url(r'^index1/tim/$', views.my_view, name='tim'),
    url(r'^bar4/$', views.ChartView_bar4.as_view(), name='i_graph1'),
    path('i_graph1/', views.bar_page4, name='i_graph1'),
    url(r'^bar5/$', views.ChartView_bar5.as_view(), name='i_graph2'),
    path('i_graph2/', views.bar_page5, name='i_graph2'),
    url(r'^bar6/$', views.ChartView_bar6.as_view(), name='i_graph3'),
    path('i_graph3/', views.bar_page6, name='i_graph3'),
    url(r'^bar7/$', views.ChartView_bar7.as_view(), name='i_graph4'),
    path('i_graph4/', views.bar_page7, name='i_graph4'),
    url(r'^bar8/$', views.ChartView_bar8.as_view(), name='i_graph5'),
    path('i_graph5/', views.bar_page8, name='i_graph5'),
    url(r'^rank/1/$', view2.zb_yj, name='zb'),
]

